<%@ page contentType="text/html; charset=UTF-8" language="java"%>
<%@ taglib uri="/tags/struts-bean" prefix="bean" %>
<%@ taglib uri="/tags/struts-html" prefix="html" %>
<%@ taglib uri="/tags/struts-logic" prefix="logic" %>
<html:html>
<html:errors/>
<head>
<meta http-equiv=Pragma content=no-cache>
<meta http-equiv=Cache-Control content=no-cache>
<meta http-equiv=Expires content=0>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title><bean:message key="login.title"/></title>
<script type="text/javascript" src="style/scripts/private.js"  language="JavaScript"></script>
<script language="javascript">

	function login(){
		document.forms[0].submit();
	}
	
	function res(){
		document.forms[0].reset();
	}
    function hback(){
         if (event.ctrlKey && event.keyCode==78){
			event.returnValue = false;
		  }                           
          jsCtrlBSKey();
	}
	function jsCtrlBSKey(e) {
		var e=window.event;
		if (e.keyCode == 13 && e.srcElement.type!="image" && e.srcElement.name!="password") {
			e.keyCode = 9;
			return;
		} else if (e.keyCode == 13 && e.srcElement.type!="image" && e.srcElement.name =="password") {
			login();
			return;
		} 
	}	
	
</script>
<style type="text/css">
<!--
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;

}
td { font-size:12px}
-->
</style>
</head>

<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onkeydown="hback()">
<html:form method="post" action="/login.do" enctype="multipart/form-data">
<table width="100%" border="0" cellspacing="0" cellpadding="0" background="style/images/loginbg.jpg">
		<tr>
				<td align="center" style="padding-top:150px; padding-bottom:50px;"><table border="0" cellspacing="0" cellpadding="0">
						<tr>
								<td><img src="style/images/login_top.gif" width="470" height="94"></td>
						</tr>
						<tr>
								<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
										<tr>
												<td width="20" background="style/images/login_left_bg.gif">&nbsp;</td>
												<td height="150" align="center" background="style/images/butterfly.jpg"><table border="0" cellpadding="3" cellspacing="2">																												
																<tr>
																		<td height="25" align="right"><img src="style/images/userid.gif" width="13" height="13" align="absmiddle">&nbsp;<bean:message key="login.username"/></td>
																		<td><html:text property="username" style="width:150px;"/></td>
																		</tr>
																<tr>
																		<td height="25" align="right" ><img src="style/images/password.gif" width="13" height="9" align="absmiddle">&nbsp;<bean:message key="login.password"/></td>
																		<td><html:password  property="password" style="width:150px; "/></td>
																		</tr>
																
																<tr>
																		<td height="35" colspan="2" align="center" valign="bottom">&nbsp;&nbsp;&nbsp;&nbsp;<input type="button" onClick="javascript:login();" class="MyButton" value='<bean:message key="login.submit"/>'>&nbsp;&nbsp;&nbsp;&nbsp;<input type="button" onClick="javascript:res();" class="MyButton" value='<bean:message key="login.reset"/>'></td>
																</tr>
																<tr>
																   <!--  
																   <td><html:link action="/locale?language=en">English</html:link></td>
																   <td><html:link action="/locale?language=zh">Chinese</html:link></td>
																   --> 
																   <td>&nbsp;<bean:message key="login.switch"/></td>
																   <td>
																   <a href="locale.do?language=en"><bean:message key="login.switchen"/></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
																   <a href="locale.do?language=zh"><bean:message key="login.switchzh"/></a></td>
																</tr>
														</table>
												</td>
												<td width="22" background="style/images/login_right_bg.gif">&nbsp;</td>
										</tr>
								</table></td>
						</tr>
						<tr>
								<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
										<tr>
												<td width="20"><img src="style/images/login_bottom_l.gif" width="20" height="19"></td>
												<td background="style/images/login_bottom_bg.gif">&nbsp;</td>
												<td width="22"><img src="style/images/login_bottom_r.gif" width="22" height="19"></td>
										</tr>
								</table></td>
						</tr>

				</table>
				<p><html:messages id="aa" message="true"><bean:message key="errors.prefix"/><bean:write name="aa"/><bean:message key="errors.suffix"/></html:messages></p>
				<p>&nbsp;</p>
				<p>Copyright&nbsp;2008&nbsp;All&nbsp;right&nbsp;reserved&nbsp;<bean:message key="login.copyright" />&nbsp;<bean:message key="login.version" />&nbsp;<br><bean:message key="login.support" /></p>				
				</td>	
		</tr>
</table>
</html:form>
</body>
</html:html>
<script language="javascript" type="text/javascript">
	document.getElementById("username").focus();
</script>